<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">











<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <title>memos2 - Introduction</title>
    <style type="text/css" media="all">
      @import url("./css/maven-base.css");
      @import url("./css/maven-theme.css");
      @import url("./css/site.css");
    </style>
    <link rel="stylesheet" href="./css/print.css" type="text/css" media="print" />
          <meta name="author" content="Simone Tripodi" />
        <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
      </head>
  <body class="composite">
    <div id="banner">
                  <a href="" id="bannerLeft">
    
                                            <img src="images/logo.png" alt="" />
    
            </a>
                        <a href="http://www.asemantics.com/" id="bannerRight">
    
                                    <img src="http://www.asemantics.com/images/logo.gif" alt="" />
    
            </a>
            <div class="clear">
        <hr/>
      </div>
    </div>
    <div id="breadcrumbs">
          
  

  
    
  
  
    
            <div class="xleft">
        Last Published: 2009-05-24
                          |   
          Version: 1.0-beta
                        </div>
            <div class="xright">            <a href="">Project Page</a>
            |
                <a href="downloads/list">Downloads</a>
            |
                <a href="http://fabrizio.zellini.org/oscache-memcached-memos" class="externalLink">memOS</a>
            |
                <a href="http://www.opensymphony.com/oscache/" class="externalLink">OSCache</a>
            |
                <a href="http://www.danga.com/memcached/" class="externalLink">Memcached</a>
            |
                <a href="../spymemcached/">Spy Memcached</a>
            
  

  
    
  
  
    
  </div>
      <div class="clear">
        <hr/>
      </div>
    </div>
    <div id="leftColumn">
      <div id="navcolumn">
           
  

  
    
  
  
    
                   <h5>memOS2</h5>
            <ul>
              
    <li class="none">
              <strong>Introduction</strong>
        </li>
              
    <li class="none">
                    <a href="user-guide.html">User's Guide</a>
          </li>
              
    <li class="none">
                    <a href="faq.html">FAQ</a>
          </li>
          </ul>
              <h5>Project Documentation</h5>
            <ul>
              
                
              
      
            
      
            
      
            
      
            
      
            
      
            
      
            
      
            
      
            
      
              
        <li class="collapsed">
                    <a href="project-info.html">Project Information</a>
                </li>
              
                
              
      
            
      
            
      
            
      
            
      
            
      
            
      
            
      
            
      
              
        <li class="collapsed">
                    <a href="project-reports.html">Project Reports</a>
                </li>
          </ul>
                                           <a href="http://maven.apache.org/" title="Built by Maven" class="poweredBy">
            <img alt="Built by Maven" src="./images/logos/maven-feather.png"></img>
          </a>
                       
  

  
    
  
  
    
        </div>
    </div>
    <div id="bodyColumn">
      <div id="contentBox">
        <div class="section"><h2>Introduction</h2>
<p>I started implementing memos2 while developing a RESTful APIs for a customer client in Paris, which explicitly requested having <a href="http://www.danga.com/memcached" class="externalLink">memcached</a>
 as a caching layer, due to internal scalability issues.</p>
<p>The project was already set up, and it was using the <a href="http://ibatis.apache.org" class="externalLink">Apache iBatis</a>
 to access to the DataBase, that natively wide supports the excellent <a href="http://www.opensymphony.com/oscache/" class="externalLink">OSCache</a>
 to store queries... so, before writing a new memcached based caching module that could be hackly plugged in <tt>iBatis</tt>
, I was looking for a quick and smart way to integrate <tt>OSCache</tt>
 and <tt>Memcached</tt>
.</p>
<p>My teacher and friend <a href="http://fabrizio.zellini.org" class="externalLink">Fabrizio Zellini</a>
 showed me a post on his blog where he talks about an implementation he made years ago called <a href="http://fabrizio.zellini.org/oscache-memcached-memos" class="externalLink">memOS</a>
, a small <tt>PersistenceListener</tt>
 for <tt>OSCache</tt>
 that wraps the <a href="http://www.whalin.com/memcached/" class="externalLink">Greg Whalin</a>
's Memcached Java Client.</p>
<p>I fount it brilliant, like a lightning in a sunny day: with just few lines of code he otained a distribuited caching system without altering any existing software based on <tt>OScache</tt>
.</p>
<p>So, I asked him the permissions to reuse, altering and adapting it for my needs: <i>voila'</i>
, I gave born to <tt>memOS2</tt>
, a <tt>PersistenceListener</tt>
 for <tt>OSCache</tt>
, based on the optimized <a href="http://code.google.com/p/spymemcached" class="externalLink">Dustin Sallings</a>
's Memcached Java Client.</p>
</div>
<div class="section"><h2>Acknowledgements</h2>
<p>I have to say a big thank to <i>Fabrizio Zellini</i>
 for his kindness, to the <tt>iBatis</tt>
 and <tt>OSCache</tt>
 teams that creating excellent products are alleviating my everyday's work, and to <i>Dustin Sallings</i>
 to maintain, with priceless hard work, the best Memcached Java Client.</p>
<p>This work is dedicated to my city, L'Aquila, destroyed by a terrible earthquake the 6th April, 2009... That day more than 300 people were killed because buildings collapsed after a magnitudo 6.3 earthquake at 3:06 am. We'll never forget that episode.</p>
</div>

      </div>
    </div>
    <div class="clear">
      <hr/>
    </div>
    <div id="footer">
      <div class="xright">&#169;  
          2009
    
          Asemantics S.r.l.
          
  

  
    
  
  
    
  </div>
      <div class="clear">
        <hr/>
      </div>
    </div>
  </body>
</html>
